package com.gzq.repository;

import com.gzq.entity.Article;
import com.gzq.entity.User;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.repository.CrudRepository;

import java.util.List;

/**
 * @description:
 * @author: duzi55
 * @date: 2019-06-03 16:11
 */
public interface ArticleRepository extends CrudRepository<Article,Long> {
    //查找全部
    Page<Article> findAll(Pageable pageable);
    //通过id删
    int deleteById(long id);
    //模糊查询
    List<Article> findByTitleLike(String title);
    //通过id查
    Article findById(long id);



}
